/*
 * @Author: wzlmm 3033603342@qq.com
 * @Date: 2022-11-15 09:36:25
 * @LastEditors: wzlmm 3033603342@qq.com
 * @LastEditTime: 2022-11-15 14:00:06
 * @FilePath: \Mock\index.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */


const Mock = require("mockjs")
const fs = require("fs")

const {
    list
} = Mock.mock({
    "list|5": [{
        "id": "@id",
        img: "@image(100x100,@color,image)",
        title: "@ctitle(5)",
        word: "@cword(10,15)",
        num: 1,
        "price|100-300":1,
        selected: false
    }]
})

fs.writeFileSync("data.json", JSON.stringify(list))